import request from '@/utils/request'

// 策略搜索
export const searchPolicyApi = params => request.get('/vm-service/policy/search', {params})

// 新增策略
export const addPolicyApi = data => request.post(`/vm-service/policy`, data)

// 修改策略
export const editPolicyApi = data => request.put(`/vm-service/policy/${data.policyId}`, data)

// 删除策略
export const delPolicyApi = id => request.delete(`/vm-service/policy/${id}`)

// 根据策略搜索售货机
export const getPolicyInfoApi = params => request.get(`/vm-service/policy/vmList/${params.policyId}`, {params})